﻿<Window x:Class="UserProfileUI.UserProfileManager"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:usrs="clr-namespace:UserProfileUI" 
        Title="Select Profile" Height="400" Width="500" 
        Icon="/UserProfileUI;component/UserIcons/favicon.ico">
    <Grid>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="250" />
            <ColumnDefinition Width="*" />
        </Grid.ColumnDefinitions>
        <Grid.RowDefinitions>
            <RowDefinition Height="*" />
            <RowDefinition Height="Auto" />
        </Grid.RowDefinitions>

        <usrs:UserListBox Grid.Column="0" Grid.Row="0" HorizontalAlignment="Stretch"
                          VerticalAlignment="Stretch" x:Name="lbxUsers" />        
        <StackPanel Grid.Row="1" Grid.ColumnSpan="2" Background="#ededed" 
                    Orientation="Horizontal" FlowDirection="RightToLeft" >
            <Button Content="Cancel" Width="60"
                    Margin="5,5,5,5" Name="btnCancel" Click="btnCancel_Click" />
            <Button Content="Okay" Width="60" IsEnabled="False"
                    Margin="5,5,5,5" Name="btnOkay" Click="btnOkay_Click" />
        </StackPanel>

        <Grid Grid.Column="1" Grid.Row="0">
            <Grid.RowDefinitions>
                <RowDefinition Height="Auto" />
                <RowDefinition Height="*" />
            </Grid.RowDefinitions>
            <Expander IsExpanded="True" Grid.Row="0">
                <Expander.Header>
                    <TextBlock Text="Add User" FontSize="18" FontWeight="DemiBold" />
                </Expander.Header>
                <Grid>
                    <Grid.Background>
                        <LinearGradientBrush>
                            <GradientStop Offset="0" Color="#efefef" />
                            <GradientStop Offset="1" Color="White" />
                        </LinearGradientBrush>
                    </Grid.Background>
                    <Grid.RowDefinitions>
                        <RowDefinition Height="10" />
                        <RowDefinition Height="Auto" />
                        <RowDefinition Height="Auto" />
                        <RowDefinition Height="Auto" />
                    </Grid.RowDefinitions>
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="Auto" />
                        <ColumnDefinition Width="*" />
                        <ColumnDefinition Width="5" />
                    </Grid.ColumnDefinitions>
                    <Label Content="Name:" FontSize="14" VerticalAlignment="Bottom"
                           Grid.Column="0" Grid.Row="2" HorizontalAlignment="Right" />
                    <TextBox Name="tbxName" Grid.Column="1" Grid.Row="2"  HorizontalAlignment="Stretch"
                             VerticalAlignment="Center" />
                    <Border Grid.Row="0" Grid.Column="0" Grid.ColumnSpan="3" CornerRadius="10" BorderBrush="Black" BorderThickness="1"
                            Margin="3" Grid.RowSpan="2">
                        <Border.Background>
                            <RadialGradientBrush SpreadMethod="Pad" RadiusX="5" RadiusY=".5">
                                <GradientStop Color="#666666" Offset="0" />
                                <GradientStop Color="Transparent" Offset="1"  />
                            </RadialGradientBrush>
                        </Border.Background>
                        <Image Name="imgUsrIcon" Mouse.MouseDown="tbxUsrIcon_MouseDown" 
                               Source="/UserProfileUI;component/UserIcons/User.png"
                               MaxHeight="120" Cursor="Hand">
                            <Image.ContextMenu>
                                <ContextMenu Name="ctmuUserIcon" >
                                    <MenuItem Click="MenuItem_Click" Header="female1.png" >
                                        <MenuItem.Icon>
                                            <Image Source="/UserProfileUI;component/UserIcons/female1.png" Stretch="Fill"
                                                   MinWidth="20" MinHeight="20" MaxHeight="75" VerticalAlignment="Stretch" 
                                                   HorizontalAlignment="Stretch" />
                                        </MenuItem.Icon>
                                    </MenuItem>
                                    <MenuItem Click="MenuItem_Click" Header="female2.png" >
                                        <MenuItem.Icon>
                                            <Image Source="/UserProfileUI;component/UserIcons/female2.png" Stretch="Fill"
                                                   MinWidth="20" MinHeight="20" MaxHeight="75" 
                                                   VerticalAlignment="Stretch" HorizontalAlignment="Stretch"/>
                                        </MenuItem.Icon>
                                    </MenuItem>
                                    <MenuItem Click="MenuItem_Click" Header="female3.png" >
                                        <MenuItem.Icon>
                                            <Image Source="/UserProfileUI;component/UserIcons/female3.png" Stretch="Fill"
                                                   MinWidth="20" MinHeight="20" MaxHeight="75" 
                                                   VerticalAlignment="Stretch" HorizontalAlignment="Stretch"/>
                                        </MenuItem.Icon>
                                    </MenuItem>
                                    <MenuItem Click="MenuItem_Click" Header="female4.png" >
                                        <MenuItem.Icon>
                                            <Image Source="/UserProfileUI;component/UserIcons/female4.png" Stretch="Fill"
                                                   MinWidth="20" MinHeight="20" MaxHeight="75" 
                                                   VerticalAlignment="Stretch" HorizontalAlignment="Stretch"/>
                                        </MenuItem.Icon>
                                    </MenuItem>
                                    <MenuItem Click="MenuItem_Click" Header="female5.png" >
                                        <MenuItem.Icon>
                                            <Image Source="/UserProfileUI;component/UserIcons/female5.png" Stretch="Fill"
                                                   MinWidth="20" MinHeight="20" MaxHeight="75" 
                                                   VerticalAlignment="Stretch" HorizontalAlignment="Stretch"/>
                                        </MenuItem.Icon>
                                    </MenuItem>
                                    <MenuItem Click="MenuItem_Click" Header="female6.png" >
                                        <MenuItem.Icon>
                                            <Image Source="/UserProfileUI;component/UserIcons/female6.png" Stretch="Fill"
                                                   MinWidth="20" MinHeight="20" MaxHeight="75" 
                                                   VerticalAlignment="Stretch" HorizontalAlignment="Stretch"/>
                                        </MenuItem.Icon>
                                    </MenuItem>
                                    <MenuItem Click="MenuItem_Click" Header="male1.png" >
                                        <MenuItem.Icon>
                                            <Image Source="/UserProfileUI;component/UserIcons/male1.png" Stretch="Fill"
                                                   MinWidth="20" MinHeight="20" MaxHeight="75" 
                                                   VerticalAlignment="Stretch" HorizontalAlignment="Stretch"/>
                                        </MenuItem.Icon>
                                    </MenuItem>
                                    <MenuItem Click="MenuItem_Click" Header="male2.png" >
                                        <MenuItem.Icon>
                                            <Image Source="/UserProfileUI;component/UserIcons/male2.png" Stretch="Fill"
                                                   MinWidth="20" MinHeight="20" MaxHeight="75" 
                                                   VerticalAlignment="Stretch" HorizontalAlignment="Stretch"/>
                                        </MenuItem.Icon>
                                    </MenuItem>
                                    <MenuItem Click="MenuItem_Click" Header="male3.png" >
                                        <MenuItem.Icon>
                                            <Image Source="/UserProfileUI;component/UserIcons/male3.png" Stretch="Fill"
                                                   MinWidth="20" MinHeight="20" MaxHeight="75" 
                                                   VerticalAlignment="Stretch" HorizontalAlignment="Stretch"/>
                                        </MenuItem.Icon>
                                    </MenuItem>
                                    <MenuItem Click="MenuItem_Click" Header="male4.png" >
                                        <MenuItem.Icon>
                                            <Image Source="/UserProfileUI;component/UserIcons/male4.png" Stretch="Fill"
                                                   MinWidth="20" MinHeight="20" MaxHeight="75" 
                                                   VerticalAlignment="Stretch" HorizontalAlignment="Stretch"/>
                                        </MenuItem.Icon>
                                    </MenuItem>
                                    <MenuItem Click="MenuItem_Click" Header="male5.png" >
                                        <MenuItem.Icon>
                                            <Image Source="/UserProfileUI;component/UserIcons/male5.png" Stretch="Fill"
                                                   MinWidth="20" MinHeight="20" MaxHeight="75" 
                                                   VerticalAlignment="Stretch" HorizontalAlignment="Stretch"/>
                                        </MenuItem.Icon>
                                    </MenuItem>
                                    <MenuItem Click="MenuItem_Click" Header="User.png" >
                                        <MenuItem.Icon>
                                            <Image Source="/UserProfileUI;component/UserIcons/User.png" Stretch="Fill"
                                                   MinWidth="20" MinHeight="20" MaxHeight="75" 
                                                   VerticalAlignment="Stretch" HorizontalAlignment="Stretch"/>
                                        </MenuItem.Icon>
                                    </MenuItem>
                                </ContextMenu>
                            </Image.ContextMenu>
                        </Image>
                    </Border>
                    <StackPanel Grid.Row="3" Grid.ColumnSpan="2" HorizontalAlignment="Right" Orientation="Horizontal"
                                FlowDirection="RightToLeft" Margin="2,2,2,2">
                        <Button Content="Add User" Name="btnAddUser" Click="btnAddUser_Click" />
                    </StackPanel>                   

                </Grid>
            </Expander>

            <Expander IsExpanded="True" Grid.Row="1">
                <Expander.Header>
                    <TextBlock Text="Description" FontSize="18" FontWeight="DemiBold" />
                </Expander.Header>
                <Grid>
                    <Grid.Background>
                        <LinearGradientBrush>
                            <GradientStop Offset="0" Color="#efefef" />
                            <GradientStop Offset="1" Color="White" />
                        </LinearGradientBrush>
                    </Grid.Background>
                    <TextBox HorizontalAlignment="Stretch" VerticalAlignment="Stretch" 
                             AcceptsReturn="True" Background="Transparent" BorderBrush="Black" 
                             TextWrapping="WrapWithOverflow" IsReadOnly="True"
                             Name="tbxDescription" Margin="5,5,5,5" />
                </Grid>
            </Expander>
        </Grid>
    </Grid>
</Window>
